package com.itdfq.springaop.demo;

import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.EnableAspectJAutoProxy;

/**
 * @Author: QianMo
 * @Date: 2021/11/17 10:27
 * @Description:开启基于注解的AOP
 */
@EnableAspectJAutoProxy
@Configuration
public class Config {
    @Bean
    public MathCalculator mathCalculator() {
        return new MathCalculator();
    }

    @Bean
    public LogAspects logAspects(){
        return new LogAspects();
    }
}
